//
//  HJGroupInviteModel.m
//  KaiChat
//
//  Created by lx on 2023/11/14.
//

#import "HJGroupInviteModel.h"

@implementation HJGroupInviteModel

+ (NSArray *)bg_uniqueKeys {
    return @[@"userId"];
}

+ (HJGroupInviteModel *)modelWithDict:(NSDictionary *)dict {
    HJGroupInviteModel *model = [[HJGroupInviteModel alloc] init];
    model.avatar = dict[@"user_avatar"];
    model.userId = toString(dict[@"user_id"]);
    model.nickname = dict[@"nickname"];
    model.timestamp = toString(dict[@"created_at"]);
    return model;
}

- (NSString *)bg_tableName {
    return [NSString stringWithFormat:@"%@_%@", NSStringFromClass(self.class), HJUserInfo.userId];
}

+ (NSString *)bg_tableName {
    return [NSString stringWithFormat:@"%@_%@", NSStringFromClass(self.class), HJUserInfo.userId];
}

@end
